#include<stdio.h>
int main(){
	int M,N,T1,T2,min;
	scanf("%d %d %d %d",&M,&N,&T1,&T2);
	min=(N/M)*T1+(T1+T2);
	printf("%d",min);
	return 0;
} 
